package com.ieng.kican.common.http.use;

import com.ieng.kican.common.http.MR;

public class ActionR {

    public static <T> MR<?> success(T data) {
        return new MR<>(0, "success", data);
    }

    public static <T> MR<?> error(String message) {
        return new MR<>(-1, message);
    }

    public static <T> MR<?> send(int code, String message) {
        return new MR<>(code, message);
    }

    public static <T> MR<?> OK() {
        return new MR<>(0, "ok");
    }

}
